package com.muyu.user.domain;

import java.math.BigDecimal;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.muyu.common.core.annotation.Excel;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import java.io.Serial;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;
import lombok.AllArgsConstructor;
import lombok.experimental.SuperBuilder;
import com.muyu.common.core.web.domain.BaseEntity;

/**
 * 消费记录数据库映射对象 sys_consumption_record
 *
 * @author liuguoqiang
 * @date 2025-09-18
 */
@Data
@SuperBuilder
@NoArgsConstructor
@AllArgsConstructor
@TableName("sys_consumption_record")
@EqualsAndHashCode(callSuper = true)
public class SysConsumptionRecord extends BaseEntity {
    @Serial
    private static final long serialVersionUID = 1L;

    /**
     * 主键ID
     */
    @TableId(value = "id",type = IdType.AUTO)
    private Long id;

    /**
     * 用户ID
     */
    private Long userId;

    /**
     * 订单ID
     */
    @Excel(name = "订单ID")
    private Long orderId;

    /**
     * 收货人
     */
    @Excel(name = "收货人")
    private String consignee;

    /**
     * 商品数量
     */
    @Excel(name = "商品数量")
    private Long productCount;

    /**
     * 商品总价
     */
    @Excel(name = "商品总价")
    private BigDecimal totalPrice;

    /**
     * 实付金额
     */
    @Excel(name = "实付金额")
    private BigDecimal actualAmount;

    /**
     * 交易完成时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Schema(name = "creatTime", title = "交易完成时间", description = "交易完成时间" )
    private Date createTime;

}
